package com.sijiao.databus;

import com.sijiao.databus.service.IStockCacheService;
import org.springframework.stereotype.Component;

@Component
public class Consumer {
    private IStockCacheService stockCacheService;

    public Consumer(IStockCacheService stockCacheService) {
        this.stockCacheService = stockCacheService;
    }

    public void consume(Object obj){
        stockCacheService.incrStock(1L);
    }

}
